import { $get, $put } from "@js/request"
import { formatCaseDataLicenseAndMobile } from '@js/tool'
import _ from 'lodash'


// 获取案件详情请求请求
export async function getCaseDetailRequest (caseid) {
  const res = await $get(`/api/xd/case/partyCaseRead/${caseid}`)
  if (res.status !== 1) {
    throw new Error(res.message)
  }
  formatCaseDataLicenseAndMobile(res.data)
  return res.data
}

export async function updateData (id, d) {
  const res = await $put(`/api/xd/case/${id}`, d)
  return res.data
}
